Overview In addition to the powerful new controls supported by ViewIt FCMD-based control drivers, ViewIt also supports the addition of older CDEF-based controls to ViewIt windows. CDEF-based controls are indicated by BaseID = CDEF ID and VersID = 0. Standard CDEF 0 Apple provides 2 standard CDEFs with IDs 0 and 1. The first of these supports the standard button, check box, and radio button controls, where the VarCode is used to define the control type: 0 = button, 1 = check box, and 2 = radio button. If 8 is added to VarCode, then the control is drawn using the window's current font settings. ViewIt uses this feature to draw these standard controls in the proper font, size, and style, so it is important to use VarCode values of 8, 9, and 10 with controls based on CDEF 0. Some features supported by FCMD-based controls are not supported by CDEF-based controls since the CDEF is unaware of our expanded control record and messages. Such features include resource linking, frame and body drawing, indentation of content area, hand scrolling, and support for editable controls. Nearly all other features, however, are supported. These include font, size, style, and color selection, addition of a ring or shadow, command key, default button, check box, and radio button behavior, data linking, and use with ViewIt commands. COLOR NOTE: The CDEF 0-based controls have the "feature" of reusing the last defined part color for all other parts that are not assigned colors. Thus setting just the "Frame" in ViewIt's Style menu to red will cause the entire control to be drawn in red unless you take the trouble to also define other part colors. This feature does not occur if using BaseCt-based controls that mimic the CDEF 0 controls. Standard CDEF 1 The second standard CDEF (ID = 1) supports scroll bars. The features supported by ViewIt are similar to those listed above for CDEF 0 controls. One difference is that ViewIt does not provide any default scroll bar behavior, meaning that you should always set the "Returns On Hit" option in the Control dialog so that your program can respond to clicks in a CDEF-based scroll bar. Other CDEFs CDEFs that support button-, check box-, or radio button-type controls can be used in ViewIt windows in the same way that the standard CDEF 0 controls are used. CDEFs that support dial-type controls can be used in the same way as standard CDEF 1 scroll bars are used. Simply set the BaseID to the custom CDEF ID, VersID to 0, & the VarCode to values supported by the CDEF. Data Linking All CDEF-based controls base data linking on the control's standard Value, where 0 = unchecked and 1 = checked for check boxes and radio buttons.